package top.shiyiri.shops.service;

import top.shiyiri.shops.bean.EraHotCateTop3;
import top.shiyiri.shops.dao.EraHotCateTop3Dao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author Aunean
 * @date 2021/12/23
 */
@Service
public class EraHotCateTop3Service {

    @Autowired
    private EraHotCateTop3Dao dao;

    public List<EraHotCateTop3> findEraHotCateTop3ByPage(int page, int size) {

        return dao.findEraHotCateTop3ByPage((page -1) * size, size);
    }

    public int totalLines() {
        return dao.totalLines();
    }

    public List<EraHotCateTop3> findEraHotCateTop3() {
        return dao.findEraHotCateTop3();
    }
}
